<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
"http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<title>Untitled Document</title>
<style type="text/css">
<!--
.style1 {
	font-size: 18px;
	font-weight: bold;
	font-style: italic;
}
.style2 {
	font-size: 24px;
	font-weight: bold;
}
.style3 {font-style: italic}
-->
</style>
</head>

<body>
<div align="center">
  <p class="style2">Campaign and Mod Creation</p>
  <p align="left">This section is for users who already got experience with Warcraft 3 modding and only want the specific information needed to make AMAI work with custom units and abilities. <br>
    <br>
        <span class="style3"><strong>Note</strong>: There is currently an issue with using the default AMAI on custom melee maps that dont use the latest melee patch data. </span>AMAI will not work past tier 1 </p>
  <p align="left"><B>Defining custom units and abilities for AMAI.</B><a name="DefineUnits"></a><BR>
  For this you need a table editor like Microsoft Excel or any other program capable of opening and saving tables file in form of tab separated text files. </p>
  <p align="left">Be-aware that Microsoft Excel has the tendency to make true and false upper case and adds extra ( &quot; ) symbols when types and such have a comma between them. e.g. mutated, worker becomes in excel &quot;mutated,worker&quot; . Make sure you change these back otherwise compile errors will occur.</p>
  <p align="left"> To add simple new custom units just edit the table file "StandardUnits.txt". There is one of these files for each version of AMAI. You find it in TFT or RoC folder together with some other table files used for adding special units that got some kind of morph abillity like Gargoyle - &gt; Statue -&gt; Gargoyle or can be upgraded to another unit like Head hunter -&gt; Berserker. The StandardUnits.txt is at least the main table for all buildings, units, abilities, upgrades and items in the game that AMAI knows of, once you open it you will understand.<BR>
    <BR>
    To add a new unit here just insert an empty line in the category where it belongs and add all the info in the columns. All columns got labels explaining what to put in them at the first line of this file and you will also understand what to enter by looking at the existing units.<BR>
    You might also want to replace a standard unit, do that by just entering new info in its line.<BR>
    <BR>
    All units that appear by using an ability from another unit or morph or cannot be built directly should have the word "mutated" in the 'type' column so they don't appear as buildable in the editor. Such units also need to be added to some of the other tables depending on what kind of transformation they come from.<BR>
    <BR>
    Upgraded units go in here too and are added to tc_add on the original units line.<BR>
  </p>
  <p align="left" class="style1">Global Setting Files:<a name="GlobalFiles"></a></p>
  <p align="left"><strong>CommandBuilds.txt </strong>= What computer builds if issued an order using the commander </p>
  <p align="left"><strong>Dragons.txt </strong>= The types of dragons that can be built from the different roosts</p>
  <p align="left"><strong>DragonTypes.txt </strong>= The Range of sizes of dragons available</p>
  <p align="left"> <strong>GlobalSettings.txt </strong>= This contains the global settings of the custom ai. This can be edited using the option on the strategy manager. (They all have comments next to them so you know what they do) </p>
  <p align="left"><strong>sleep_multiplier</strong> // increases performance by checking stuff not so often<br>
    <strong>slm_start</strong> // how many computer players is needed tor the sleep multiplier to start increasing.<br>
    <strong>slm_end </strong>// how many computer players is needed tor the sleep multiplier to stop increasing.<br>
    <strong>slm_start_mult </strong>// how much is the sleep multiplied when it&acute;s below the slm_start codition<br>
    <strong>slm_end_mult </strong>// how much is the sleep multiplied when it&acute;s above the slm_end codition<br>
    <strong>hero_radius</strong> // scanning this small area around hero to detect if the hero gets surrounded by enemy or is in danger of becoming that so it should move<br>
    <strong>use_linear_upkeep_saving</strong> // should the computers save the upkeep threshold gold over the time above or save it all at once when it get's to the upkeep border?<br>
    <strong>repair_threshold</strong> // computers only repair buildings if they have more than this many workers<br>
    <strong>repair_threshold_threatened</strong> // computers only repair buildings when the town is under attack if they got more than this many workers<br>
    <strong>max_follow_dist</strong> // Distance behind the arme a zeppelin follows<br>
    <strong>neutral_hero_time </strong>// when is neutral heroes available in seconds /5<br>
    <strong>buy_distance </strong>// how close to a shop do a unit have to be for buying?<br>
    <strong>buy_timeout_large</strong> // time in seconds the hero goes to a shop before it gives up if it haven't reached it<br>
    <strong>buy_timeout_small</strong> // time in seconds a hero tries to buy items at shop before giving up<br>
    <strong>build_array_reset_time</strong> // every this * 5 seconds, the build array is reset<br>
    <strong>rp_strat_normal </strong>// normalizing strategy priorities added from strengths with this value<br>
    <strong>strategy_tier_bonus</strong> // the priority bonus added to a strategy if the computer is in the same tier as specified for the strategy<br>
    <strong>attacking_strategy</strong> // strategy when attacking enemy players<br>
    <strong>focus_fire_limit</strong> // if a enemy heros hp fall below the computers combined strength of ranged attackers in a battle * this, they will focus fire on the hero<br>
    <strong>focus_fire_ranged_dist </strong>// Distance from ranged units enemy units can be targeted with focus fire<br>
    <strong>focus_fire_melee_dist </strong>// Distance from melee units enemy units can be targeted with focus fire<br>
    <strong>flee_health_percentage</strong> // Units flee from battle if the health goes below his % value(0.25 = 25%)<br>
    <strong>flee_minimum_health </strong>// Units flee from battle if the health goes below this<br>
    <strong>statue_distance</strong> // how near the units a statue used by undead should be in the fights<br>
    <strong>teleport_radius</strong> // units will stay within this radius from a hero that is using town portal<br>
    <strong>gold_exchange_level </strong>// computers give extra gold above this value to other computers on the same team in need of gold<br>
    <strong>wood_exchange_level</strong> // computers give extra lumber above this value to other computers on the same team in need of lumber<br>
    <strong>max_towns</strong> // how many towns is a computer allowed to have?<br>
    <strong>add_tag</strong> // Add the [AMAI] tag in front of name<br>
    <strong>add_skill</strong> // Add the current skill after the name<br>
    <strong>fav_hero_add</strong> // priority added to heroes to be picked if they are favorites of the used profile<br>
    <strong>max_harass_groups</strong> // how many different harass groups you can use<br>
    <strong>attacking_aggression</strong> // the base agression value for all computers, higher value and they will play more agressive. Recomended -5 to 5<br>
    <strong>expansion_radius</strong> // the radius araound a mine computers check for creeps before expanding there<br>
    <strong>harass_radius_attack_ranged</strong> // how far away from ranged enemy units harassing units attack a inferior enemy unit<br>
    <strong>harass_radius_attack_melee</strong> // how far away from melee enemy units harassing units attack a inferior enemy unit<br>
    <strong>harass_radius_flee_ranged</strong> // how far away from ranged enemy units harassing units turn and flee<br>
    <strong>harass_radius_flee_melee</strong> // how far away from melee enemy units harassing units turn and flee<br>
    chatting true computers use chat taunts<br>
    <strong>full_threat_distance</strong> // a enemy army within this distance is counted as a full threat<br>
    <strong>no_threat_distance</strong> // a enemy army outside this distance is counted as no threat<br>
    <strong>distance_threat_exponent</strong> // how fast the threat increases as the enemy army gets from the no_threat_distance to the full_threat_distance<br>
    <strong>distance_threat_mult</strong> // how much the threat vlaue goes up on a rown when a enemy army aproashes, higher value means higher threat to town<br>
    <strong>atl_time_start</strong> // accepted threat level increase starts at this time<br>
    <strong>atl_time_end</strong> // and ends at that time<br>
    <strong>atl_time_start_val</strong> // it starts with this value<br>
    <strong>atl_time_end_val </strong>// and ends with that value<br>
    <strong>atl_enemy_start</strong> // accepted threat level multiplier increases at that enemy number<br>
    <strong>atl_enemy_end</strong> // until that enemy number<br>
    <strong>atl_enemy_start_mult</strong> // the multiplier starts for accepted threat level starts with this<br>
    <strong>atl_enemy_end_mult </strong>// and ends with this<br>
    <strong>teleport_low_threat </strong>// Army uses TP to get home and defend if a threat is greater than this and the army is more far away from thretened town than teleport_low_threat_distance<br>
    <strong>teleport_high_threat </strong>// Army uses TP to get home and defend if a threat is greater than this and the army is more far away from thretened town than teleport_high_threat_distance<br>
    <strong>teleport_low_threat_distance </strong>// Army won't use TP home if they are closer to base than this and a low threat level appears<br>
    <strong>teleport_high_threat_distance</strong> // Army won't use TP home if they are closer to base than this and a high threat level appears<br>
    <strong>teleport_army_min_strength</strong> // how big the army need to be for use of TP to threatened town<br>
    <strong>teleport_min_threat </strong>// minimum threat level TP use is allowed on<br>
    <strong>shredder_peon_count</strong> // how many peons does a goblin shredder replace in lumber harvesting<br>
    <strong>minimum_peon_wood </strong>// computers don't build any workers for lumber harvesting if they have more lumber than this<br>
    <strong>maximum_peon_wood</strong> // computers build all needed workers for lumber harvesting if they have lumber lower than this<br>
    <strong>ver_neutral_heroes_available</strong> // does the version have neutral heroes ?<br>
    <strong>ver_neutral_hero_number</strong> // how many neutral heroes ?<br>
    <strong>ver_only_heroes_buy</strong> // can only heroes buy stuff ?<br>
    <strong>ver_food_limit </strong>// what is the versions food limit ?<br>
    <strong>normal_battle_radius </strong>// units within that radius are considered belonging to the current battle<br>
    <strong>creep_battle_radius</strong> // same as with normal_battle_radius, but for battles against creeps<br>
    <strong>expansion_taken_radius</strong> // how near a mine a enemy building must be to make amai recognize it as taken<br>
    <strong>ver_strat_change_enemy_strength_min</strong> // don't allow strategy change unless the maximum strength of all enemy players in the game is above this.<br>
    <strong>ver_hero_base_value</strong> // what is the base strength of a hero (the level number is added to get the actual strength) ?<br>
    <strong>ver_hero_ultimate_level</strong> // at what level do the heroes get their ultimates ?<br>
    <strong>ver_hero_ultimate_value</strong> // how much extra strength does the ultimate give to the hero ?<br>
    <strong>ver_creeps_attack_buildings_dist</strong> // how far away do creeps attack buildings ?<br>
    <strong>ver_mercs_night_buy </strong>// can mercs be bought at night without waking up creeps ?<br>
    <strong>ver_tower_check_radius </strong>// check for towers in this radius around a target<br>
    <strong>ver_harass_tower_check_radius </strong>// check for towers in this radius during harassing<br>
    <strong>destroy_buildings_on_defeat</strong> // Should the buildings of the AI be destroyed on defeat or given to neutral player ?<br>
    <strong>ver_gold_mines </strong>// what are the gold mine ids in this version (in TFT that is Set3('ngol','egol','ugol') ) ?<br>
  <strong>attack_reform_length</strong> // reform the attack group (getting new units) every that time on an attack (in seconds / 2)<br>
  <strong>front_base_distace</strong>// the distance of front of base from start location<br>
  </p>
  <p align="left"><strong>Healers.txt </strong>= The different units that can do healing. The heal order codes are as follows.</p>
  <ol>
    <li>
      <div align="left">	852160 = Rejuvenation</div>
    </li>
    <li>
      <div align="left">852063 = Heal</div>
    </li>
    <li>
      <div align="left"> 852109 = Healing Ward</div>
    </li>
    <li>
      <div align="left"> 852545 = Essence of Blight</div>
    </li>
    <li>
      <div align="left"> 852248 = Neutral Hostile Heal </div>
    </li>
  </ol>
  <p align="left">Healertypes</p>
  <ul>
    <li>
      <div align="left">SUDDEN</div>
    </li>
    <li>
      <div align="left">WARD</div>
    </li>
    <li>
      <div align="left">CONTINUOUS</div>
    </li>
    <li>
      <div align="left">NO_TARGET<BR align="left">
      </div>
    </li>
  </ul>
</div>
<div align="left">
  <p><strong>HeroAbilities.txt</strong> = Add new abilities that your heros can learn or edit.</p>
  <p><strong>HeroLevels.txt </strong>= Range of levels your heros can go up to</p>
  <p><strong>HealingItems.txt </strong> = Healing items that can be used by the ai</p>
  <p><strong>Mercs.txt </strong>= Mercenaries that can be brought from the different mercenary camps</p>
  <p><strong>MercTypes.txt </strong>= Types used for the column headings in Mercs.txt (Remember to change those headings if you change these). I reccomend not to change this file. </p>
  <p><strong>NeededExtra.txt </strong>= If a unit has more needs that cannot be fitted into the standardunits.txt, put them here</p>
  <p><strong>NeutralHeroSkills.txt = </strong>The skill orders that neutral heros use. The ability names are in the HeroAbilities.txt. See heroSkills.txt below for more information. </p>
  <p><strong>Profiles.txt </strong>= This is the raw txt file of your profiles. You should not need to edit this as you use the strategy manager instead.</p>
  <p><strong>Races.txt </strong>= The available races the ai can use and the script files it creates. The example layout of this file is below </p>
  <table width="500" border="1">
    <tr>
      <td>RACE</td>
      <td>AMAI script </td>
      <td>Original Blizzard entertainment script </td>
    </tr>
  </table>
  <p>Note by changing the original blizzard entertainment script selections to custom made scripts and placing that custom script in the version folder you can see how your ai plays against AMAI when you compile the AMAI vs AI version. </p>
  <p><strong>StrengthPredictionRules.txt </strong>= This contains conditions that are used to predict changes to an enemies strength so AMAI can react before it actually happens. This file has not yet been officially tested so use at your own risk. </p>
  <p><strong>Strengths.txt </strong>= The strength names. I reccomend not to change as you then have to change loads of other files which had the old strength names in. </p>
  <p><strong>UnitConversions.txt </strong>= Where unit conversions are placed  like 'Archer + Hippo -&gt; Hippo rider' </p>
  <p><strong>UnitEquivelence.txt </strong>= Where extra upgraded forms go if there is no space in the standardunits.txt file or if you want to use special equivelences.</p>
  <p>e.g. UPGRADED_TO or BUILT_FROM </p>
  <p><strong>Upkeep.txt </strong>= Settings that monitor the upkeep.</p>
  <p>FoodValueBorders = The places where upkeep become low or high<BR>
    Resistance = Amount of gold to save before entering desired upkeep level<BR>
    SaveTime = How many seconds *5 the computer should wait and save money before entering upkeep level<br>
    MinesNeeded = Number of mines to have before entering upkeep level </p>
  <p class="style1">Racial Setting Files : <a name="RacialFiles"></a></p>
  <p><strong>BuildSequence.ai: </strong>= This is the data of your strategy builds. Do not change. Use the strategy Manager instead. Strategy Manager also allows you to change the racial global builds that are always built no matter what strategy the ai uses.</p>
  <p><strong>CommandBuilds.ai </strong>= Units race builds when issued an order from the commander.</p>
  <p><strong>Heros.txt </strong>= The heros the race can build and there different proities to be built. Be aware that the first heros must be the neutral heroes. The number of rows that count as neutral are set in the global settings file. If neutralheroes = 0 then first heros will just be normal ones. </p>
  <p><strong>HeroSkills.txt </strong>= The skill orders for the racial heros. The ability names are set in HeroAbilities.txt. These skill lists must be for heros defined in same order as in the heros.txt document. Each hero will in total have 9 skill lines(3 for tier 1, 3 for tier 2, 3 for tier 3) . The format example is below. <br>
  </p>
  <table width="100%" border="1">
    <tr>
      <td>Tier</td>
      <td>Priority</td>
      <td>Abilitiy names </td>
    </tr>
    <tr>
      <td>1</td>
      <td>60</td>
      <td>list of 10 abilities </td>
    </tr>
    <tr>
      <td>&nbsp;</td>
      <td>30</td>
      <td>list of 10 abilities </td>
    </tr>
    <tr>
      <td>&nbsp;</td>
      <td>10</td>
      <td>list of 10 abilities </td>
    </tr>
    <tr>
      <td>2</td>
      <td>60</td>
      <td>list of 10 abilities </td>
    </tr>
  </table>
  <p><strong>RaceAgression.txt </strong>= Agression of race against the other races.</p>
  <p><strong>RacialSettings.txt = </strong>Global values for the race and what special abilities race can do. Use the strategy Manager to edit this instead of editing directly here. (The settings have comments next to them so you know what they do)</p>
  <p><strong>hero1_revive_prio </strong>// priority for reviving hero1<br>
    <strong>hero2_revive_prio</strong> // priority for reviving hero2<br>
    <strong>hero3_revive_prio</strong> // priority for reviving hero3<br>
    <strong>prio_n_inc </strong>// priority increase for building needed buildings<br>
    <strong>prio_t_inc </strong>// priority increase in time<br>
    <strong>prio_q_inc</strong> // priority increase in quantity<br>
    <strong>farm_food</strong> // build farm when this near food used to food produced<br>
    <strong>farm_food2 </strong>// builds another farm at the same time when this near food used to food produced<br>
    <strong>farm_prio </strong>// priority for farm building<br>
    <strong>peon_prio</strong> // priority for peon building<br>
    <strong>expa_prio</strong> // priority for expansion building<br>
    <strong>expa_emergency_prio</strong> // priority for making expansion when it's an emergensy (current mine/mines + own resources are about to be depleted)<br>
    <strong>expa_rebuild_prio</strong> // priority for rebuilding an expansion<br>
    <strong>peon_1_mine_number</strong> // number of peons to build when 1 mine is owned<br>
    <strong>peon_2_mines_number</strong> // number of peons to build when 2 mines are owned<br>
  <strong>peon_mines_number</strong> // number of peons to build when more mines are owned<br>
  <strong>min_peon_number_single_mine</strong>	//	minimum number of peons when 1 mine is owned<br>
  <strong>min_peon_number_multi_mine</strong> // minimum number of peons when more than 1 mine is owned<br>
    <strong>strat_persistence</strong> // extra added priority to the current strategy to make computer not change strategy too fast<br>
    <strong>strat_food_persistence</strong> // * current food use added to priority for current strategy (prevents computers from changing styrategy when having large army)<br>
    <strong>relevant_strat_change_number</strong> // number of strategies with highest RPs that can be chosen when changing strategy<br>
    <strong>kb_add1 </strong>// priority added to all strategies having a building the computer already got as a key building<br>
    <strong>kb_add2 </strong>// priority added to all strategies having a building the computer already started to build as key building<br>
    <strong>kb_add3</strong> // priority added to all strategies having both building the computer already got as key buildings<br>
    <strong>kb_add4</strong> // value for 2 of a key buildings<br>
    <strong>ku_add1</strong> // priority added to all strategies having a upgrade the computer already got as key upgrade in first level<br>
    <strong>ku_add2</strong> // priority added to all strategies having a upgrade the computer already got as key upgrade in second level<br>
    <strong>ku_add3 </strong>// priority added to all strategies having a upgrade the computer already got as key upgrade in third level<br>
    <strong>fav_unit_add</strong> // priority added to strategies havign the current profiles favorite unit as key units.<br>
    <strong>debug_strategy </strong>// this race is locked to this strategy number for testing.(-1 is unlocked)<br>
    <strong>race_use_fountain </strong>// does the race use healing fountains ?<br>
    <strong>race_manual_loading </strong>// does the race need manual loading of wisps in goldmines ?<br>
    <strong>race_manual_loading_wisp</strong> // What is the unit to load ?<br>
    <strong>race_manual_loading_mine</strong> // What unit is it loaded in ?<br>
    <strong>race_towerrush_available</strong> // does the race have a towerrush ?<br>
    <strong>race_tower_orderstring</strong> // the orderstring for building the tower for towerrush<br>
    <strong>race_militia_expansion_available </strong>// does the race have a militia expansion ?<br>
    <strong>race_hero_number</strong> // how many racial heroes ?<br>
    <strong>race_simple_melee</strong> // a basic melee unit, only necessary when basic_melee is used<br>
    <strong>race_advanced_melee </strong>// an advanced melee unit to replace the basic one, only necessary when basic_melee is used<br>
    <strong>race_has_ghouls</strong> // has the race a ghoul-like wood harvester/fighter unit ?<br>
    <strong>race_has_power_build </strong>// can multiple racial workers work on the same building ?<br>
    <strong>race_no_wood_harvest </strong>// has the race no wood harvesters ?<br>
    <strong>race_ignore_injured </strong>// should the race leave injured units at home ?<br>
    <strong>race_uses_mine_expansion</strong> // does the race expand with a mine building like undead ?<br>
    <strong>race_uses_shredder </strong>// does the race use the goblin shredder ?<br>
    <strong>race_militia_available</strong> // does the race have militia ?<br>
    <strong>race_militia_max_distance </strong>// how far away from the town hall are the militia allowed ?<br>
    <strong>race_militia_ability</strong> // what is the militia ability id ?<br>
    <strong>race_militia_hall_ability </strong>// what is the militia ability of the hall ?<br>
    <strong>race_militia_unitstring</strong> // what is the unitstring/name of the militia ?<br>
    <strong>race_militiaworker_unitstring</strong> // what is the string of the unit that can be turned to militia ?<br>
    <strong>use_militia_only_on_bigger_threats </strong>// shall the computer only use militias against larger threats ?<br>
    <strong>race_towerrush_requirement </strong>// what is the building required to build towers ?<br>
    <strong>race_ghouls_attack</strong> // do those ghouls go with the army on attacks ?<br>
    <strong>race_ancient_expansion_available </strong>// can the race expand with an uprooted building that also helps fighting the creeps ?<br>
    <strong>race_ancient_expansion_probability</strong> // how high (in percent) is the probability of doing an ancient expansion when possible ?<br>
    <strong>race_ancient_expansion_strength</strong> // up to how much expansion strength is an ancient expansion allowed ?<br>
    <strong>race_ancient_expansion_hero1</strong> // allow ancient expansion for that hero<br>
    <strong>race_ancient_expansion_hero2</strong> // allow ancient expansion for that hero<br>
    <strong>race_sell_ziggurats</strong> // does the race sell ziggurats that are at no more needed expansions ?<br>
    <strong>race_ziggurats </strong>// for selling ziggurats, a set of ziggurats the race has (use old ids)<br>
  <strong>race_ziggurat_keep_distance </strong>// keep ziggurat if this near another building except a ziggurat is</p>
  <p>&nbsp;</p>
  <p><strong>Strategy.txt </strong>= File that stores the strategies of the race. Use the strategy manager to create and edit strategies instead of editing here.</p>
  <p><strong>Tiers.txt</strong> = The available tiers that the race has. </p>
  <p class="style1">The next files are files outside of the ROC and TFT folder and are just in the AMAI folder</p>
  <p><strong>Versions.txt </strong>= The different versions available. So adding version &quot;yuck&quot; would require folder &quot;yuck&quot; to be created which has all the files above in as if it is another TFT folder. Scripts folder also needs a folder of this name to store the create scripts at that location.</p>
  <p><strong>Jobs.txt </strong>= This calls the functions in the Jobs folder. Those files all end in .eai and can be edited in notepad for advanced users.</p>
  <p><strong>Common.eai </strong>= Open in notepad but can be edited by advanced users. Main file of AMAI to create common.ai script. (Contains main globals of ai's)</p>
  <p><strong>HeroFleeRules. ai =</strong>Controls the flee control of heros. Can be edited by advanced users</p>
  <p><strong>.j extension files =</strong>Can be edited by advanced users. </p>
  <p><strong>Blizzard.eai </strong>= Can be edited by advanced users. Main file of AMAI to create blizzard.j scripts. (Contains all the commander and language functions) </p>
  <p><strong>Race.eai =</strong>Can be edited by advanced users. Main file of AMAI to create racial script ai's. </p>
  <p><strong>keywords.txt</strong>= key words used in all ai scripts. This file is used for optimizing the ai scripts so dont go changing it. </p>
  <p><strong>Adding into your campaign.</strong></p>
  <p>First import scripts into your campaign. You could rename them if they are only being used at a particular mission e.g. human01.ai. Then in the map that wants to use them, do &quot;run campaign ai&quot; or &quot;run melee ai&quot; somewhere (initialisation is best if no in game cinematic playing at beginning of map) and select your imported ai script. (campaign ai prevents parts of the scripts from running which melee ai would have) </p>
  <p>If you leave the script names as human.ai, orc.ai etc and change there location in map to scripts/ you can just use melee - run ai scripts action to run them.</p>
  <p><strong>Upgrading your AMAI<a name="Upgrade"></a></strong></p>
  <p>As AMAI is improved you may wish to upgrade your AMAI to use new features and to take advantage of new developer settings. AMAI is very easy to update unless we give specific instructions on release. </p>
  <p>First download the new developer edition and extract to appropiate place. Copy your amai version folder over to the new amai directory.</p>
  <p>Open versions.txt and add the name of your custom amai. Save and close.</p>
  <p>Now run &quot;apply table changes.pl&quot; and all the nessary updates are applied to your custom amai so that you may continue to use it. </p>
  <p><strong>Using AMAI's commander system </strong><a name="Commander"></a></p>
  <p>AMAI's commander system is very powerful in allowing players to issue orders to there allies when a player presses the esc key. Custom game makers can use this to there advantage to make some direct control of AMAI in a custom map who may wish to control the AMAI in some way. There is a trigger command in the world editor that allows you to issue commands to a computer 'AI-Issue command' or you can use the common.j native CommandAI() if you prefer scripting. Basically certain combinations of command and data orders will make AMAI do something. I shall list the results of the commands below. </p>
  <table width="100%" border="1">
    <tr>
      <td width="63">Command</td>
      <td width="43">Data</td>
      <td width="851">Result</td>
    </tr>
    <tr>
      <td>0</td>
      <td>N/A</td>
      <td>Cancels all custom commands and default control given back to AMAI </td>
    </tr>
    <tr>
      <td>1</td>
      <td>N/A</td>
      <td>Cancels build order 
   commands and control given back to AMAI </td>
    </tr>
    <tr>
      <td>2</td>
      <td>N/A</td>
      <td>Cancels all attack orders and control given back to AMAI </td>
    </tr>
    <tr>
      <td>10</td>
      <td>N/A</td>
      <td>Stop AMAI's current attack</td>
    </tr>
    <tr>
      <td>11</td>
      <td>N/A</td>
      <td>Makes AMAI no longer attack until all attack orders are cleared using command 2</td>
    </tr>
    <tr>
      <td>12</td>
      <td>(0-12)</td>
      <td>Make AMAI attack the player number given in the data</td>
    </tr>
    <tr>
      <td>13</td>
      <td>N/A</td>
      <td>Makes AMAI attack a point. You must issue another command with this where the new command is the x point and the data is the y point otherwise this will not work</td>
    </tr>
    <tr>
      <td>14</td>
      <td>N/A</td>
      <td>Makes AMAI no longer attack creeps</td>
    </tr>
    <tr>
      <td>15</td>
      <td>N/A</td>
      <td>Makes AMAI no longer attack players</td>
    </tr>
    <tr>
      <td>16</td>
      <td>(0-12)</td>
      <td>Makes AMAI attack the current selected unit of the player given in the data</td>
    </tr>
    <tr>
      <td>17</td>
      <td>N/A</td>
      <td>Make AMAI tower rush (only works if the race can towerrush) </td>
    </tr>
    <tr>
      <td>50</td>
      <td>N/A</td>
      <td>Turn AMAI chatting systems on and off </td>
    </tr>
    <tr>
      <td>51</td>
      <td>N/A</td>
      <td>Turn AMAI debugging systems on and off </td>
    </tr>
    <tr>
      <td>52</td>
      <td>N/A</td>
      <td>Balancing debug system turns on to report strengths of enemies etc </td>
    </tr>
    <tr>
      <td>53</td>
      <td>N/A</td>
      <td>Stops AMAI from changing its current strategy</td>
    </tr>
    <tr>
      <td>60</td>
      <td>N/A</td>
      <td>Displays Current Strategy Name </td>
    </tr>
    <tr>
      <td>61</td>
      <td>N/A</td>
      <td>Displays All Strategy Names </td>
    </tr>
    <tr>
      <td>70</td>
      <td>0 -&gt; </td>
      <td><p>Forces AMAI to change strategy. The data contains a value that depicts what strategy number to change to. </p>      </td>
    </tr>
    <tr>
      <td>71</td>
      <td>row</td>
      <td>AMAI changes language to the that in the languages.txt file on that chosen row. First row is 0 </td>
    </tr>
    <tr>
      <td>20</td>
      <td>0 -&gt; </td>
      <td>Forces AMAI to build the amount specified in data of air2air units </td>
    </tr>
    <tr>
      <td>21</td>
      <td>0 -&gt; </td>
      <td>Forces AMAI to build the amount specified in data of air2ground units </td>
    </tr>
    <tr>
      <td>22</td>
      <td>0 -&gt; </td>
      <td>Forces AMAI to build the amount specified in data of ground2air units </td>
    </tr>
    <tr>
      <td>23</td>
      <td>0 -&gt; </td>
      <td>Forces AMAI to build the amount specified in data of ground2ground units </td>
    </tr>
    <tr>
      <td>24</td>
      <td>0 -&gt; </td>
      <td>Forces AMAI to build the amount specified in data of farm units </td>
    </tr>
    <tr>
      <td>25</td>
      <td>0 -&gt; </td>
      <td>Forces AMAI to build the amount specified in data of tower units </td>
    </tr>
  </table>
  <p>N/A = Value is Ignored<br>
    0-&gt; = May use any value
</p>
</div>
</body>
</html>
